package chapter06.e27;

interface Inter<T> {
    public abstract void show(T t);
}
class InterImpl<T> implements Inter<String> {
    //@Override帮助检查重写是否正确
    @Override
    public void show(String t) {
        System.out.println(t);
    }
}
    public class E27 {
        public static void main(String[] args) {
            Inter<String> inter = new InterImpl<>();
            inter.show("hello ");
        //    inter.show(1);//无法传入非String类型数据
        }

    }

